package com.shaoshaohuo.app.entity;

import java.io.Serializable;

/**
 * Created by cao on 2016/2/22.
 */
public class Specification implements Serializable {

    public String id;
    public String specification_name;
    public String specification_val;
    public String is_checkbox;
    public String t_pid;

    @Override
    public boolean equals(Object o) {
        if (!(o instanceof Specification) || o == null) return false;
        Specification specification = (Specification) o;
        return specification.id.equals(id) && specification.t_pid.equals(t_pid) &&
                specification.specification_name.equals(specification_name) &&
                specification.specification_val.equals(specification_val);
    }

    @Override
    public int hashCode() {
        return Integer.parseInt(id + t_pid);
    }
}
